home *** CD-ROM | disk | FTP | other *** search
/ Digitalfoto 118 / Digitalfoto 118.iso / mac / programas / 00 / start.swf / scripts / frame_1 / DoAction_2.as < prev    next >
Text File  |  2009-11-16  |  1KB  |  43 lines

  1. function decodeMacPath(s)
  2. {
  3.    var _loc3_ = [["\\","/"]];
  4.    var _loc1_ = 0;
  5.    while(_loc1_ < _loc3_.length)
  6.    {
  7.       var _loc5_ = s.toLowerCase();
  8.       var _loc2_ = 0;
  9.       var _loc6_ = 0;
  10.       while(_loc5_.indexOf(_loc3_[_loc1_][0],_loc2_ + _loc6_) != -1)
  11.       {
  12.          _loc2_ = _loc5_.indexOf(_loc3_[_loc1_][0],_loc2_ + _loc6_);
  13.          s = s.substring(0,_loc2_) + _loc3_[_loc1_][1] + s.substr(_loc2_ + _loc3_[_loc1_][0].length);
  14.          _loc5_ = s.toLowerCase();
  15.          _loc6_ = _loc3_[_loc1_][1].length;
  16.       }
  17.       _loc1_ = _loc1_ + 1;
  18.    }
  19.    return s;
  20. }
  21. function openFolder(arg)
  22. {
  23.    if(client_os == "Mac")
  24.    {
  25.       arg = decodeMacPath(arg);
  26.    }
  27.    file_path = appdir + wfiles_folder + arg;
  28.    mdm.System.exec(file_path);
  29. }
  30. function openImage(arg)
  31. {
  32.    if(client_os == "Mac")
  33.    {
  34.       arg = decodeMacPath(arg);
  35.    }
  36.    file_path = appdir + arg;
  37.    mdm.System.exec(file_path);
  38. }
  39. function saveFile(__path, __content)
  40. {
  41.    mdm.FileSystem.saveFileUnicode(__path,__content);
  42. }
  43.